1. Field of the Invention
The present application relates to computer system profiling and more specifically to profiling application codes executed in the computer system.
2. Description of the Related Art
Generally, system profiling applications on a computer system allow users to collect data regarding various elements of the computer system at different execution stages of an application code. Typically, users collect system data to determine the performance of the application code. The system data can include states of different components (e.g., various registers, internal states of processors, selected memory locations, various controllers and the like) at various data collection points in the application code. The data collection is typically driven by timer or performance/event counters. The user can specify a timing interval and/or identify a number of selected events for which the profiling application can collect system data.
When specified timing interval or number of identified events occur, interrupts are generated and the interrupt service routines collect system data. The interrupts are generated based on the timing interval and/or event counters. After the data is collected, the user can correlate the data collected based on the timing intervals with the data collected based on the event counters. In a multiprocessing system, where many processors run independently, it is difficult to determine the exact timing interval when a specified number of events may occur. Thus, to profile a computer system, the user has to ran many cycles of data collection to be able to correlate data collected based on timing intervals with the data collected based on event counters. A system and method is needed to efficiently profile a computer system.